﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Douban.Api.Authorization
{
    public interface IAccessTokenManager
    {
        /// <summary>
        /// Store token in some place
        /// </summary>
        /// <param name="token"></param>
        /// <param name="secret"></param>
        void StoreToken(string token, string secret);

        /// <summary>
        /// Get the token
        /// </summary>
        /// <returns>the key is token, value is tokenSecret</returns>
        KeyValuePair<string, string> GetToken();

        /// <summary>
        /// Clear access token
        /// </summary>
        void Clear();

        /// <summary>
        /// Check whether the specific token type is available
        /// </summary>
        bool IsTokenAvailable { get; }
    }
}
